<!DOCTYPE html>
<html lang="en" style="height: 100%;">

<head>
	<meta charset="UTF-8">
	<meta name="viewport"
		content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0" />
	<meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
	<title>手机快速注册</title>
	<link rel="stylesheet" type="text/css" href="../../css/api.css" />
	<link rel="stylesheet" type="text/css" href="../../css/style.css" />
	<link rel="stylesheet" type="text/css" href="../../css/yzl.css" />
	<link rel="stylesheet" type="text/css" href="../../css/vant.css" />
	<style>
		.input-center {
			margin: 0 auto;
			/*height: 60px;*/
			width: 100%;
			line-height: 40px;
		}

		input {
			/*line-height: 60px;*/
			outline: none;
			border-radius: 5px;
		}


		.register-btn {
			background: #33375E;
		}

		.input-center input {
			border: none;
		}

		.aui-checkbox {
			width: 16px;
			height: 16px;
			vertical-align: middle;
		}

		.v-enter,
		.v-leave-to {
			opacity: 0;
		}

		.v-enter-active,
		.v-leave-active {
			transition: opacity 1.5s;

		}
		.saoma{
			position: absolute;
			width:84px;
			height: 30px;
			/*margin-top: -25px;*/
			text-align: center;
			line-height: 30px;
			color: #F95656;
			border-radius:  15px;
			border:1px solid #F95656;
			font-size: 12px;
			right:0px
		}
	</style>
</head>

<body style="background:#ffffff">
	<div id="blank" class="header" v-cloak>
		<div v-back.tapmode class="back"></div>
		<div class="title">注册</div>
	</div>
	<div id="app" v-cloak >
		<div style="width:100%;padding: 0 5%;padding-top:80px;box-sizing: border-box;">
			<div class="regis-head">
				<img :src="authinfo.headimgurl"/>
				<div  class="regis-head-xinxi">
					<div style="font-size: 18px;font-weight: bold;margin-bottom: 15px;">{{authinfo.nickname}}</div>
					<div style="font-size: 12px;color: #999">注册授权微信号</div>
				</div>
			</div>
			<van-cell-group>
		  <van-field v-model="phone" placeholder="请输入手机号" type="tel"/>
		</van-cell-group>
			<div class="next_botton" :class="{'next_botton_active':phone}" v-myclick="next">下一步</div>

		</div>
	</div>
</body>
	<script src="../../script/api.js"></script>
	<script src="../../script/vue.js"></script>
	<script src="../../script/app.js"></script>
	<script src="../../script/common.js"></script>
	<script src="../../script/url.js"></script>
	<script src="../../script/components.js"></script>
	<script src="../../script/vant.min.js"></script>

	<script>

		var pageParam,
				phone,
				vm;
		var talkingData;
		apiready = function () {
			setBSImg();
			new Vue({
				el: '#blank',
			});
			wap_url = getPrefs("wap_url");
			talkingData = api.require('talkingData');
			pageParam = api.pageParam;
			initApp();
			api.parseTapmode();
			addListeners();
		};

		function initApp() {
			var isBigImg = Vue.BSImg == 'big';
			vm = new Vue({
				el: '#app',
				data: {
					authinfo: pageParam,
					phone:phone,
				},
				methods: {
					next: function() {
						var data = {
								phone: this.phone,
								picVerification: 1,
								picTimeStamp: 222111,
						};
						if(!(/^1(3|4|5|6|7|8|9)\d{9}$/.test(this.phone))){
							alert("请输入正确的手机号");
							return false;
						}
						showProgress();
						var that = this;
						var callback = function (ret) {
							var params=that.authinfo;
							params['phone'] = that.phone;
							params['islogin'] = ret.content.isLogin;
							params['timeStamp'] = ret.content.timeStamp;
							api.openWin({
							    name: 'setInfo',
							    url: './setInfo.html',
							    pageParam: {
							        params: params
							    }
							});

						};
						var errback = function (ret) {

						};
						pinet.post(APIURLP+'/play/register/getPhoneVerification', data, callback, errback);
					},
				},
				watch: {

				}
			})
		}
		function addListeners() {
			// api.addEventListener({
			// 	name: 'viewdisappear'
			// }, function (ret, err) {
			// 	closeWin('setInfo');
			// });
		}

	</script>
</body>

</html>
